Use BD_SYS_ALMACEN
Go
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE Procedure [dbo].[GRSubCategoria_x_Categoria](
   @iCodCat Int
)
As
Begin

   Select 
      iCodSub,
      iCodCat, 
      vNomSub,
      vDesSub,
      bActivoSub,
      iCodUsu,
      cNomTer,
      dtFecAct
   From GRSubCategoria a(Nolock)   
   Where iCodCat = @iCodCat
   
End